package com.hoshiicloud.market.feign;

import com.hoshiicloud.market.feign.hystrix.HystrixIdGeneratorFeignFallback;
import java.util.Set;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @author zhangshuhu
 * @title: IdGeneratorService
 * @projectName hoshiicloud
 * @description: 主键服务
 * @since 2019-05-21
 */
@FeignClient(name = "hoshiicloud-id-generator", fallback = HystrixIdGeneratorFeignFallback.class)
public interface IdGeneratorService {

    /**
     * 获取主键
     *
     * @return String
     */
    @GetMapping("/getuuId")
    String queryGeneratorId();

    @GetMapping(value = "/getComUserCode")
    String getComUserCode();

    @GetMapping(value = "/getPlatCousomerCode")
    String getPlatCousomerCode();

	/**
	 * 获取uuid
	 *
	 * @param count count
	 * @return Set
	 */
	@RequestMapping(value = "/getuuIdSet")
	Set<String> queryGeneratorIds(@RequestParam("count") Integer count);
}
